/**
 * this => 对象
 * @type {Object}
 */
var obj = {
  name: 'andy',
  say: function() {
    console.log(this.name);
    console.log(this);
    console.log(this === obj);
  }
};

obj.say();

/**
 * this => global
 * @param  {[type]} name [description]
 * @return {[type]}      [description]
 */
function objFunc(name) {
  console.log(name);
  console.log(this === global);
}

objFunc('andy');

function Obj(iname) {
  this.name = iname;
  this.say = function() {
    console.log(this.name);
    console.log(this);
    console.log(this === objInstance); //true
    console.log(this === Obj); // false
  };
}

var objInstance = new Obj('andy');
objInstance.say();